package com.embedsky.administrator.mycardreader.util;

import java.io.Closeable;
import java.io.IOException;

/**
 * The type Safe close util.
 *
 * @Des: SafeCloseUtil
 * @Author: linhui.shi
 * @Date: 2021 /2/25 16:11
 */
public class SafeCloseUtil {
    /**
     * Close the closeable obj.
     *
     * @param closeable the closeable
     */
    public static void close(Closeable closeable) {
        if (null != closeable) {
            try {
                closeable.close();
            } catch (IOException e) {
                LogUtil.d("SafeCloseUtil", "SafeCloseUtil close: " + e.getMessage());
            }
        }
    }
}
